package org.ithang.application.staticBonus.service;

import java.util.List;
import java.util.Map;
import org.ithang.application.staticBonus.mapper.StaticBonusMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.apache.log4j.Logger;
import org.ithang.tools.model.Pager;
import org.ithang.tools.database.ModelDao;
import org.ithang.application.staticBonus.bean.StaticBonus;

/**
 * 静态分润 服务
 * @author zyt
 *
 */
@Service
public class StaticBonusService extends ModelDao<StaticBonus>{

    @Autowired
    private StaticBonusMapper staticBonusMapper;

    private Logger logger = Logger.getLogger(StaticBonusService.class);
    
    public void add(StaticBonus staticBonus){
        staticBonusMapper.add(staticBonus);
    }
    
    public StaticBonus get(Long id){
        return staticBonusMapper.get(id);
    }
    
    public int delete(Long id){
        return staticBonusMapper.delete(id);
    }
    
    public int batchDelete(String[] ids){
    	return staticBonusMapper.batchDelete(ids);
    }
    
    public List<StaticBonus> list(Long... ids){
    	return staticBonusMapper.list(ids);
    }
    
    public List<StaticBonus> page(Pager<StaticBonus> page){
    	return staticBonusMapper.page(page);
    }
    
    public Double getTamount(Pager<StaticBonus> page){
    	return staticBonusMapper.tmount(page);
    }
    
    public List<StaticBonus> query(Map<String,Object> conditions){
    	return staticBonusMapper.query(conditions);
    }
    
    public int update(StaticBonus staticBonus){
    	return staticBonusMapper.update(staticBonus);
    }
    
    
}